<!doctype html>
<html>

<head>
	<meta charset="utf-8">
	<meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
	<meta name="format-detection" content="telephone=no" />
	<title>消息</title>
	<link rel="stylesheet" type="text/css" href="../c/aui.css" />
	<link rel="stylesheet" type="text/css" href="../c/redian.css" />
	<style>
		.zuduo #img{
			width: 3rem;
		}
		.zuduo #img img{
			border-radius: 0.15rem;
		}
		.zhanshi{
			text-align: center;
			opacity: 0.5;
			font-size: 0.65rem;
			padding: 1rem 0;
			display: none;
		}
	</style>
</head>

<body>
	<script id="sx-list" type="text/x-dot-template">
		{{ for(var i=0,it=it; i < it.length; i++) { }}
		<li class="aui-list-item aui-list-item-middle" tapmode onclick="video_list({{= it[i].id}})" id="id{{= it[i].id}}" data-data='{{= JSON.stringify(it[i])}}'>
			<div class="aui-media-list-item-inner">
				<div class="em">{{= i>=3 ? (i+1) : ''}}</div>
				<div class="aui-list-item-media" id="img">
					<img suxiangw-src="{{= _img(it[i].img,200,300,it[i].img?false:true) }}" src="../i/loading_b.png">
				</div>
				<div class="aui-list-item-inner aui-ellipsis">
					<div class="aui-ellipsis-2" id="username">
						{{= it[i].content}}
					</div>
					{{? api.pageParam['index'] == 0}}
					<div id="info">播放量<b>{{= it[i].click}}</b>次</div>
					{{?? api.pageParam['index'] == 1}}
					<div id="info">评论量<b>{{= it[i].ping_num}}</b>条</div>
					{{?? api.pageParam['index'] ==2}}
					<div id="info">点赞量<b>{{= it[i].zan_num}}</b>个</div>
					{{?}}
				</div>
			</div>
		</li>
		{{ } }}
	</script>
	<div class="aui-card-list zuduo">
		<ul class="aui-list aui-media-list" id="sx-view">
			<div id="loadingdi_huifu" style=" margin-top:50% "><img src="../i/footer_progress.png" /></div>
		</ul>
		<div class="zhanshi">最多展示50条数据</div>
	</div>
</body>
<script type="text/javascript" src="../j/api.js"></script>
<script type="text/javascript">
	var url = ['click','ping_num','zan_num'];
	apiready = function() {
if(adName){
	_init_ad();
	ad = api.require(adName);
}

		list();
		_shangla(function(ret,err){
			list();
		},1)
	}
	function list() {
		banner();
		_ajax('video/lists/order/'+url[api.pageParam['index']]+'/limit/50', function(ret, err) {
			if (ret.data.length) {
				var evalData = doT.template($api.html($api.byId('sx-list')));
				$api.html($api.byId('sx-view'), evalData(ret.data));
				_loadingCloes();
				$('.zhanshi').show();
				api.parseTapmode();
				_imageCache();
			} else {
				$('#sx-view').html('<div id="loadingNo" class="meiyoushju" style="padding-top:70%;">没数据啦，多多互动吧 ~ </div>');
			}
		})
	}
	// 打开滑动视频
	function video_list(id){
		banner();
		var data = $('#id'+id).data('data');
		_video_list(data,'zuiduo');
	}
</script>

</html>
